/**
  * 功能描述: 基础密码输入框样式表
  * @author 崔孝楠
  * @date 2022/9/20 14:39
  * @version 1.0
  */
@import '../../style/index';
// 密码框布局
@mixin password--layout {
  position: relative;
  box-sizing: border-box;
  margin: 0;
  display: inline-block;
  width: 100%;
  min-width: 0;
  padding: 4px 11px;
  line-height: $line-height-base;
}
// large 布局
@mixin password-lg--layout {
  padding: 6.5px 11px;
}
// 密码框样式
@include b(password) {
  font-variant: tabular-nums;
  list-style: none;
  font-feature-settings: 'tnum';
  color: $color-text-primary;
  font-size: $input-font-size;
  background-color: $color-white;
  background-image: none;
  border: $border-base;
  border-radius: $border-radius-small;
  transition: all 0.3s;
  @include password--layout;
  // 占位符样式
  @include placeholder {
    color: $color-text-placeholder;
    -webkit-user-select: none;
    -moz-user-select: none;
    user-select: none;
    opacity: 1;
  };
  // 占位符布局
  &:placeholder-shown {
    text-overflow: ellipsis;
  }
  // 悬浮样式
  &:hover {
    border-color: $color-primary;
    border-right-width: $border-width-base !important;
  }
  // 聚焦样式
  &:focus, &-focused {
    border-color: $color-primary;
    box-shadow: $input-focus-box-shadow;
    border-right-width: $border-width-base !important;
    outline: 0;
  }
  // 禁用样式
  &[disabled] {
    color: $disabled-color-base;
    background-color: $background-color-base;
    border-color: $border-color-base;
    box-shadow: none;
    cursor: not-allowed;
    opacity: 1;
  }
  // 禁用时悬浮
  &[disabled]:hover {
    border-color: $border-color-base;
    border-right-width: $border-width-base !important;
  }

}
// large 样式
@include b(password-lg) {
  font-size: $input-font-size-lg;
  @include password-lg--layout
}
// small 布局
@include b(password-sm) {
  padding: 0px 7px;
}
